package com.geek.javase.ch18.work.work5;

/*
 *@Date 2025/11/7
 *@Author wangpeng
 *@Description TODO
 */
/*public class Test {
    public static void main(String[] args) {
        //目标对象
        Calculator calculator = new Calculator();
        //代理对象
        DynamicProxyCalculateLog proxy = new DynamicProxyCalculateLog(calculator);
        ICalculator iCalculator = proxy.getProxy();

        iCalculator.add(1,2);
        iCalculator.sub(1,2);
        iCalculator.mul(1,2);
        iCalculator.div(1,2);

    }
}*/
public class Test {
    public static void main(String[] args) {
        //目标对象
        ICalculator target = new Calculator();
        //代理对象
        ICalculator proxy = new DynamicProxyCalculateLog(target).getProxy();

        proxy.add(1,2);
        proxy.sub(1,2);
        proxy.mul(1,2);
        proxy.div(1,2);

    }
}
